ODBCDatabase Class

Used to open an ODBC database.

Events

None

Properties

Attribute

AttributeString

DataSource


Methods

None

More information available in parent classes: Database:Object



Notes

In order to use this class, you must install the appropriate database plug-in in your plugins folder.

The set of database plug-ins is included on the REALbasic CD, but you may find more recent versions at the REAL Software web site, http://www.realsoftware.com.

The ODBCDatabase class also requires a third-party driver manager and driver. REALbasic supports OpenLink's ODBC Driver manager and drivers (www.openlinksw.com) and Merant/Metro Technologies ODBC Manager. OpenLink supports both Mac OS 8/9 and Mac OS X, while Merant currently does not support Mac OS X. A driver manager must be installed as well as the driver for whichever database back end you wish to access. Check REAL Software's web site, http://www.realsoftware.com, for updated drivers.


Example

This example presents an open-file dialog box in which you can select an ODBC database.

Dim db as ODBCDatabase
db= New ODBCDatabase
db.DataSource=""
If db.Connect then
 //proceed with database operations
else
  MsgBox "The connection failed."
end if

See Also

Database, DatabaseField, DatabaseRecord, RecordSet classes.